package com.itmeng.sh.controller;

import com.itmeng.sh.dao.OrderMapper;
import com.itmeng.sh.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RequestMapping("/order")
@RestController
public class OrderController {

    @Autowired   //默认以对象
    OrderMapper orderMapper;

    @GetMapping("/all")
    public List<User> finfBy(){

        return orderMapper.all();
    }
}
